export default {
    state: {
    	// 正在付款的订单
    	orderNo:'',
		//正在付款的交易订单
		tradeNo:'',
		//正在交易的用户id
		userId:0,
    },
    mutations: {
		setOrderNo(state,status){
			state.orderNo = status;
		},
		setTradeNo(state,status){
			state.tradeNo = status;
		},
		setUserId(state,status){
			state.userId = status;
		}
    },
    getters: {
		// 正在付款的订单
		orderNo(state, getters) {
			return state.orderNo;
		},
		//正在付款的交易订单
		tradeNo(state, getters) {
			return state.tradeNo;
		},
		//正在交易的用户id
		userId(state, getters) {
			return state.userId;
		},
    },
	actions: {
	    setOrderNo (context,state) {
	      context.commit('setOrderNo',state)
	    },
		setTradeNo (context,state) {
		  context.commit('setTradeNo',state)
		},
		setUserId (context,state) {
		  context.commit('setUserId',state)
		}
	}	
}